package com.wjh.controler;

import com.wjh.bean.User;
import com.wjh.bean.User1;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

@Controller
@RequestMapping("/user1")
public class User1Controler {
    @RequestMapping(value = "/{name}",method = RequestMethod.GET)
    public @ResponseBody User1 getUser(@PathVariable String name,@RequestParam(value = "id")int id){
        User1 user1=new User1();
        user1.setId(id);
        user1.setName(name);
        System.out.println(",,,,,,");
        return user1;
    }
}
